package com.example.testlib

// 常量与变量
object ValAndVarExample {
    const val t2 = "heiheihei"
}

const val t1 = "hahaha"

class Person {

    companion object {
        const val t3 = "hehehe"
    }

    var age: Int = 0
        get() {
            return field.plus(10)
        }
        set(value) {
            field = value - 1
        }

    val name: String = ""
        get() {
            return field + "haha"
        }

    val height: Float
        get() {
            return (age * 2F + 10)
        }
}